package com.ruoyi.operation.service.impl;

import java.util.List;
import java.util.Map;

import com.ruoyi.operation.domain.LessonInfo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.operation.mapper.ProductsInfoMapper;
import com.ruoyi.operation.domain.ProductsInfo;
import com.ruoyi.operation.service.IProductsInfoService;

/**
 * 商品信息Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-05-07
 */
@Service
public class ProductsInfoServiceImpl implements IProductsInfoService 
{
    @Autowired
    private ProductsInfoMapper productsInfoMapper;

    /**
     * 查询商品信息
     * 
     * @param id 商品信息主键
     * @return 商品信息
     */
    @Override
    public ProductsInfo selectProductsInfoById(Long id)
    {
        return productsInfoMapper.selectProductsInfoById(id);
    }

    /**
     * 查询商品信息列表
     * 
     * @param productsInfo 商品信息
     * @return 商品信息
     */
    @Override
    public List<ProductsInfo> selectProductsInfoList(ProductsInfo productsInfo)
    {
        return productsInfoMapper.selectProductsInfoList(productsInfo);
    }

    /**
     * 新增商品信息
     * 
     * @param productsInfo 商品信息
     * @return 结果
     */
    @Override
    public int insertProductsInfo(ProductsInfo productsInfo)
    {
        return productsInfoMapper.insertProductsInfo(productsInfo);
    }

    /**
     * 修改商品信息
     * 
     * @param productsInfo 商品信息
     * @return 结果
     */
    @Override
    public int updateProductsInfo(ProductsInfo productsInfo)
    {
        return productsInfoMapper.updateProductsInfo(productsInfo);
    }

    /**
     * 批量删除商品信息
     * 
     * @param ids 需要删除的商品信息主键
     * @return 结果
     */
    @Override
    public int deleteProductsInfoByIds(Long[] ids)
    {
        return productsInfoMapper.deleteProductsInfoByIds(ids);
    }

    /**
     * 删除商品信息信息
     * 
     * @param id 商品信息主键
     * @return 结果
     */
    @Override
    public int deleteProductsInfoById(Long id)
    {
        return productsInfoMapper.deleteProductsInfoById(id);
    }

    @Override
    public LessonInfo selCourse(Map map) {
        return null;
    }
}
